<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.EditCustomerorderTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_id}" for="id" />
                    <h:inputText id="id" value="#{customerorderController.selected.id}" title="#{bundle.EditCustomerorderTitle_id}" required="true" requiredMessage="#{bundle.EditCustomerorderRequiredMessage_id}"/>
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_amount}" for="amount" />
                    <h:inputText id="amount" value="#{customerorderController.selected.amount}" title="#{bundle.EditCustomerorderTitle_amount}" required="true" requiredMessage="#{bundle.EditCustomerorderRequiredMessage_amount}"/>
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_confirmationNumber}" for="confirmationNumber" />
                    <h:inputText id="confirmationNumber" value="#{customerorderController.selected.confirmationNumber}" title="#{bundle.EditCustomerorderTitle_confirmationNumber}" required="true" requiredMessage="#{bundle.EditCustomerorderRequiredMessage_confirmationNumber}"/>
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_createdDate}" for="createdDate" />
                    <h:inputText id="createdDate" value="#{customerorderController.selected.createdDate}" title="#{bundle.EditCustomerorderTitle_createdDate}" required="true" requiredMessage="#{bundle.EditCustomerorderRequiredMessage_createdDate}">
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:inputText>
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_canceledDate}" for="canceledDate" />
                    <h:inputText id="canceledDate" value="#{customerorderController.selected.canceledDate}" title="#{bundle.EditCustomerorderTitle_canceledDate}" >
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:inputText>
                    <h:outputLabel value="#{bundle.EditCustomerorderLabel_customerid}" for="customerid" />
                    <h:selectOneMenu id="customerid" value="#{customerorderController.selected.customerid}" title="#{bundle.EditCustomerorderTitle_customerid}" required="true" requiredMessage="#{bundle.EditCustomerorderRequiredMessage_customerid}">
                        <f:selectItems value="#{customerController.itemsAvailableSelectOne}"/>
                    </h:selectOneMenu>
                </h:panelGrid>
                <h:commandLink action="#{customerorderController.update}" value="#{bundle.EditCustomerorderSaveLink}"/>
                <br />
                <br />
                <h:link outcome="View" value="#{bundle.EditCustomerorderViewLink}"/>
                <br />
                <h:commandLink action="#{customerorderController.prepareList}" value="#{bundle.EditCustomerorderShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:link outcome="/admin/admin.xhtml" value="#{bundle.EditCustomerorderIndexLink}" />
            </h:form>
        </ui:define>
    </ui:composition>

</html>
